<form class="form-search" action="" onsubmit="reload();return false">
    <div class="input-append">
        <input type="text" class="span2 search-query" style="width:180px" name="account" value="{$input}" placeholder="请输入查询的账户名称">
        <button type="submit" class="btn">搜索</button>
    </div>
</form>
<table class="table table-bordered">
        <tbody>
                <tr>
				<td style="background:#F5F5F5">用户账号:</td><td colspan="3"><input type="text" disabled value="{$list.account}" id="company_name"/>
				<if condition="$list.active eq 1" ><span class="label label-success label-hover" style="margin-left:5px;">已经激活</span>
				<else />
				<span class="label label-info" style="margin-left:5px">未激活语音服务，如需激活，请点击</span><span class="label label-important label-hover" style="margin-left:5px;cursor:pointer" onclick="active({$list.uid})">激活</span>
				</if>
				</td></tr>
                <tr><td style="background:#F5F5F5">账号ID</td><td><span class="label">{$list.uid}</span></td><td style="background:#F5F5F5">企业联系人:</td><td><input type="text"  disabled value="{$list.contact_telphone}" id="contact_telphone"/></td></tr>
                <tr><td style="background:#F5F5F5">联系手机:</td><td><input type="text"  disabled value="{$list.contact_mobilephone}" id="contact_mobilephone"/></td><td style="background:#F5F5F5">电子信箱:</td><td><input type="text"  disabled value="{$list.email}" id="industry"/></td></tr>
                <tr><td style="background:#F5F5F5">企业名称:</td><td><input type="text" disabled value="{$list.company_contacter}" id="company_contacter"/></td><td style="background:#F5F5F5">企业地址:</td><td><input type="text" value="{$list.company_address}" disabled/></td></tr>
				<tr><td>绑定Cloopen独立应用ID激活：</td><td><input type="text" value="" id="appid"/>
				<if condition="$list.active eq 1" ><span class="label label-success label-hover" style="margin-left:5px;">已经激活</span>
				<else />
				<span class="label label-info" style="margin-left:5px">未激活语音服务，如需激活，请点击</span><span class="label label-important label-hover" style="margin-left:5px;cursor:pointer" onclick="active2({$list.uid})">激活</span>
				</if></td></tr>
        </tbody>
</table>


<script>
	function reload(){
		
		$("#maincontent").load('__APP__/Voice/activateVoiceService',{account:getInputValueByName('account')});
	}
	function active($uid){
		$("#maincontent").load('__APP__/Voice/activateVoiceService',{uid:$uid});
	}
	function active2($uid){
		var $appid = $('#appid').val();
		$("#maincontent").load('__APP__/Voice/activateVoiceService',{uid:$uid,appid:$appid});
	}
</script>
